﻿#include "ComputeArea.h"
#include "libmesh/equation_systems.h"
#include "libmesh/mesh_generation.h"
#include "Mesh.h"

int main(int argc, char** argv) 
{
  //auto& tracker = vtkm::cont::GetRuntimeDeviceTracker();
  //tracker.ForceDevice(vtkm::cont::DeviceAdapterTagSerial{});

  libMesh::LibMeshInit init(argc, argv);

  poisson::Mesh mesh(init.comm());
  libMesh::MeshTools::Generation::build_cube(mesh, 1000, 1000, 0, -1., 1., -1., 1., 0, 0, libMesh::QUAD4);
 
  using namespace libMesh;
  EquationSystems es(mesh);
  es.add_system<CalculateArea>("simple system");
  auto& sys = es.get_system<CalculateArea>(0);
  sys.solve();

  return 0;
}